const tabItems = document.querySelectorAll("#npc_rrdscpjl_list .tab .tabItem");
const showItems = document.querySelectorAll("#npc_rrdscpjl_list .inner .widget-content");

tabItems.forEach((item, index) => {
const showItem = showItems[index];
if (index !== 0) {
item.classList.add("is-active");
} else {
showItem.style.display = "none";
}

item.addEventListener("click", () => {
tabItems.forEach(tab => tab.classList.remove("is-active"));
showItems.forEach(show => show.style.display = "none");
item.classList.add("is-active");
showItem.style.display = "block";
});
});